//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//

package cn.intotw.rdcj.core.config.mybatis.wrapper;

import cn.intotw.rdcj.core.config.mybatis.entity.Page;
import org.apache.ibatis.reflection.MetaObject;
import org.apache.ibatis.reflection.wrapper.DefaultObjectWrapperFactory;
import org.apache.ibatis.reflection.wrapper.ObjectWrapper;

public class CustomObjectWrapperFactory extends DefaultObjectWrapperFactory {
    public CustomObjectWrapperFactory() {
    }

    public boolean hasWrapperFor(Object object) {
        return object instanceof Page ? true : super.hasWrapperFor(object);
    }

    public ObjectWrapper getWrapperFor(MetaObject metaObject, Object object) {
        return (ObjectWrapper)(object instanceof Page ? new PageWrapper(metaObject, (Page)object) : super.getWrapperFor(metaObject, object));
    }
}
